<?php
require_once( PHP_PATH . 'common.php' );
$message = "";
if( isset( Url::$pageVars[ 'GETPOST' ][ 'addExpenseBtn' ] ) ) {
	try{
		ExpenseUtility::addExpense( Url::$pageVars[ 'GETPOST' ] );
		header( 'Location: /expenses/' );
		exit;
	}catch( Exception $ex ){
		$message = $ex->getMessage();
	}
}
$template->teams = Utility::getUserTeams();
$template->message = $message;
$template->title = "Add Your Expense";
$template->welcomeMsg = "Add Your Expense";
